<template>
  <div>
    <!-- 导航栏 -->
    <van-nav-bar
      title="电子协议"
      left-arrow
      :border="false"
      fixed
      @click-left="$utils.back($route.path);"
    />
    <div class="has-top"></div>

    <!-- 移动端浏览pdf组件 -->
    <pdf-preview :url="url"></pdf-preview>
  </div>
</template>

<script>
import pdfPreview from 'components/pdf'
export default {
  components: {
    pdfPreview
  },
  data() {
    return {
      url: 'http://mozilla.github.io/pdf.js/web/compressed.tracemonkey-pldi-09.pdf'
    }
  },
  created() {},
  beforeRouteLeave(to, from, next) {
    this.$toast.clear()
    next()
  }
}
</script>

<style lang="scss" scoped>
</style>
